ODROID-GO compatible M5STACK Library

Moderators: odroid, mdrjr

ODROID-GO compatible M5STACK Library

Unread postby Kabron » Fri Jul 27, 2018 1:52 am

I modified native arduino M5STACK library to suite both M5STACK and ODROID-GO.
Look in the examples folder.
Also read comments in M5Stack.h
Tested with VisualMicro for Visual Studuo

Could not upload via forum engine, so take it here:
https://yadi.sk/d/0wo7ympO3Zc6RT

odroid.jpg
odroid.jpg (82.45 KiB) Viewed 1778 times

odroid1.jpg
odroid1.jpg (104.26 KiB) Viewed 1778 times
User avatar
Kabron
 
Posts: 48
Joined: Sun Feb 24, 2013 9:01 pm
languages_spoken: english
ODROIDs: U2, ODROID-GO

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Fri Aug 10, 2018 3:18 pm

Not sure how I missed this - great!
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby jutleys » Sun Aug 12, 2018 6:33 pm

where do you place the files on root of sd?
jutleys
 
Posts: 53
Joined: Fri Jul 20, 2018 1:06 am
languages_spoken: english
ODROIDs: Odroid Go

Re: ODROID-GO compatible M5STACK Library

Unread postby Kabron » Sun Aug 12, 2018 7:22 pm

jutleys wrote:where do you place the files on root of sd?

Copy content of the folder
M5Stack-0.2.0\examples\SD_Menu\SD_content_ODROID-GO
directly to SD card root
User avatar
Kabron
 
Posts: 48
Joined: Sun Feb 24, 2013 9:01 pm
languages_spoken: english
ODROIDs: U2, ODROID-GO

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Tue Aug 14, 2018 11:16 pm

In order to launch the apps, I'm guessing one needs to flash them or create fw versions of them, right?
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby Kabron » Tue Aug 14, 2018 11:38 pm

mad_ady wrote:In order to launch the apps, I'm guessing one needs to flash them or create fw versions of them, right?

You only need to compile and flash any one of the applications(e.g. SD menu) and copy SD_content folder to SD card.
Then turn on device with btnA pressed. (Not need in case SD menu flashed) SD menu app loaded from SD and present disk menu.
In the future to add new application you only need to add in code
#include "M5StackUpdater.h"
and
if (digitalRead(BUTTON_A_PIN) == 0) {
Serial.println("Setup Will Load menu binary");
updateFromFS(SD, "/menu.bin");
ESP.restart();
}
Details:
https://github.com/tobozo/M5Stack-SD-Updater
User avatar
Kabron
 
Posts: 48
Joined: Sun Feb 24, 2013 9:01 pm
languages_spoken: english
ODROIDs: U2, ODROID-GO

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Wed Aug 15, 2018 12:20 am

Thanks, I'll give it a try
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Thu Aug 16, 2018 11:19 pm

I've made some quick fw files from the bins you provided. You can get them here: https://mega.nz/#F!o8pVWLJT!U5TCD1WWSmXLqKYIqXRtFg and flash them like a regular emulator.

Some notes:
*menu.bin: Navigation with the Menu key. A - info, B - Load. Does not actually load the other apps (saved them as bin on the root of the SD).
*PacketMonitor: Has a buzz from the speaker. Start changes channel.
*MultiApp: Menu - left arrow. B = Select, A - right arrow. Has a mini file manager and can open jpg files. Works really nice
*Pacman: Screen is garbled (like color static)
*PacMon: Start changes channels
*WifiAnalyzer: Looks pretty neat. Has no controls. Has a buzz from the speaker.
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby fixmero » Sun Aug 19, 2018 6:23 am

awesome job. thanks for this port :)

works fine, only button mapping seems to be wrong, maybe you could check this.
and can you please give a little introducing how you did compile this binarys? what tools are needed?

thanks in advance
fixmero
 
Posts: 1
Joined: Sun Aug 19, 2018 6:15 am
languages_spoken: english
ODROIDs: GO

Re: ODROID-GO compatible M5STACK Library

Unread postby Calin » Thu Sep 13, 2018 1:31 pm

I am the author of M5Stack MultiApp.
I just got the Odroid-Go...
Now i can adapt the multiApp to work properly on it.
Calin
 
Posts: 4
Joined: Thu Sep 13, 2018 1:24 pm
languages_spoken: english
ODROIDs: Odroid-Go

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Thu Sep 13, 2018 1:40 pm

We're looking forward to it, thanks!
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby danhans42 » Thu Sep 13, 2018 10:41 pm

Possible daft question...

Can this be used to flash standard IDF files or is it just for binaries built using the M5stack arduino libaries?

Thanks
danhans42
 
Posts: 19
Joined: Thu Jun 30, 2016 4:38 am
languages_spoken: english
ODROIDs: C2

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Tue Oct 09, 2018 8:04 pm

Here's a fw built from @calin's code for your convenience. Button mapping is improved (Down arrow, A, B). Sound works in Web Radio and MP3 playback (though the internal DAC's quality is kind of low for music - there are hisses in the background). I haven't been able to test video playback - I don't know what video formats are supported.
You can put mp3s on your sd card and play them from the file browser (though it didn't see all the mp3s I placed there and played a different one).

Good job, @Calin! I hope to see improvements in the future as well.

Build instructions for linux:
Code: Select all
pip install -U platformio
git clone https://github.com/botofancalin/Odroid-Go-MultiApp.git
cd Odroid-Go-MultiApp/
platformio run
ls -l .pioenvs/odroid_esp32/firmware.*
platformio run --target upload

The last command will flash your GO if connected via serial. If you want to package the firmware.bin to a fw file, you need to prepare a 86x48 png image for the loader and use mkfw to create a bin file:
Code: Select all
ffmpeg -i icon.png -f rawvideo -pix_fmt rgb565 icon.raw
~/development/odroid-go-firmware/tools/mkfw/mkfw "M5Stack MultiApp" icon.raw 0 16 2097152 app .pioenvs/odroid_esp32/firmware.bin


Download link: http://www.mediafire.com/file/abi2mtms2 ... re.fw/file
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby raystream » Mon Oct 15, 2018 7:31 pm

hi

i have downloaded your fw file.
When i try to use the webradio it does not find the webradio.txt config file.
the same with the weather app cant find the weather txt config.
raystream
 
Posts: 3
Joined: Mon Oct 15, 2018 7:29 pm
languages_spoken: english
ODROIDs: go

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Mon Oct 15, 2018 7:46 pm

Right. You'll need to add the files from here to the root of your SD card:
https://github.com/botofancalin/M5Stack ... er/SD_Data
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby raystream » Mon Oct 15, 2018 8:08 pm

i have copied those files to the root of the sd card.
but the problem is the same:

RadioStations.txt Not Found on SD
WeatherParams.txt Not Found on SD
raystream
 
Posts: 3
Joined: Mon Oct 15, 2018 7:29 pm
languages_spoken: english
ODROIDs: go

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Mon Oct 15, 2018 8:16 pm

Have you rebooted the GO after copying the files? Have you safely removed the SD card?
For me it works with the files there.
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby Calin » Fri Oct 19, 2018 12:41 am

Hi there.

@raystream The firmware read the card on power on. Reboot the GO after inserting the card.
You can check if the card is detected on system Informations menu fon MultiApp.
Make sure you use a god quality sdcard.
I found that some cheap old SD cards don't work well on SPI...
Calin
 
Posts: 4
Joined: Thu Sep 13, 2018 1:24 pm
languages_spoken: english
ODROIDs: Odroid-Go

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Fri Oct 19, 2018 1:28 pm

@Calin: will you consider building and releasing a fw file on github? It would be better than what I've shared.
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby raystream » Fri Oct 19, 2018 4:08 pm

my sd card is working fine.
i can use the go play and all emulators without problems.
only thing is that multiapp does not find the sd card.

How do i reset the go?
raystream
 
Posts: 3
Joined: Mon Oct 15, 2018 7:29 pm
languages_spoken: english
ODROIDs: go

Re: ODROID-GO compatible M5STACK Library

Unread postby mad_ady » Fri Oct 19, 2018 4:43 pm

The go play firmware has some compatibility changes to work with more sd cards. The changes are mostly made in the esp-idf environment.
User avatar
mad_ady
 
Posts: 4736
Joined: Wed Jul 15, 2015 5:00 pm
Location: Bucharest, Romania
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1

Re: ODROID-GO compatible M5STACK Library

Unread postby Calin » Sat Oct 20, 2018 3:03 am

mad_ady wrote:@Calin: will you consider building and releasing a fw file on github? It would be better than what I've shared.


I just finished the project that kept me busy for the last month.
Now i have time for Odroid-GO.
The firmware from github is under development and any contribution will be appreciated.
Contributors can a branch then start a pull request to add the code to master branch.

The firmware is made using Visual Studio Code and PlatformIO
Check the repository readme to learn to compile and flash the multiapp to GO


I tested the firmware by uploading directly to GO.
I didn't used the GO play firmware to load the multiapp.
I will take a look on it to see what's the problem with the sdcard.
Calin
 
Posts: 4
Joined: Thu Sep 13, 2018 1:24 pm
languages_spoken: english
ODROIDs: Odroid-Go


Return to Projects

Who is online

Users browsing this forum: No registered users and 2 guests