Skip to main content

Posts

Showing posts from July, 2015

[LEGO nxt] Install the Enhanced NXT firmware and Upload the OSEK excutable file with Ubuntu 64bits 14.04 in 2015

This tutorial is referred from Install the Enhanced NXT firmware on NXT . I think this is the critical part to capture the idea from the tutorial for Windows. I have tried many ways to conquer the problem of libnxt3.0, however, I still have some problems on the compilation of fwflash or something else. Though the tutorial for Windows is doable, my preference is to build up everything with Linux environment. Fortunately, I notice that NxTTool in the tutorial for Windows is really powerful. We can handle the firmware updating by using NxTTool in Linux as well! I also refer to this Japanese Blog , which inspire me a lot. As usual, install the required packages: sudo apt-get install libusb-dev:i386 libusb-0.1-4 subversion fpc Please note, here is the case for 64bits user that I change libusb-dev to libusb-dev:i386 comparing to the original tutorial. Instead of using libnxt to do the uploading, here I follow that JP Blog to get the latest version of bricxcc: (The url in blog i...

[LEGO nxt] Set up OSEK build tree on Ubuntu 64bits 14.04 in 2015

As we have the ARM cross compiler in the previous quest, now we can set up the environment of OSEK build tree. I take a reference from Set up nxtOSEK , and update some out-date information. All the concepts are repeatable in VirtualBox with same environment. First, install the wine: sudo apt-get install wine Then, download nxtOSEK from here http://sourceforge.net/projects/lejos-osek/files/nxtOSEK/ nxtOSEK_v218.zip is the latest version currently. And a patch from TOPPERS: wget http://www.toppers.jp/download.cgi/osek_os-1.1.lzh Merge them accordingly. Under ecrobot directory, update tool_gcc.mak file to specify with the variable GNUARM_ROOT the path to the installed GNU ARM directory. # specify GNU-ARM root directory ifndef GNUARM_ROOT GNUARM_ROOT = /[absolute path to parent directory of gnuarm]/gnuarm endif Then we can change directory to nxtOSEK/samples_c/helloworld directory and build binary executables of helloworld sample with the following commands: ~$ cd ./n...

[LEGO nxt] Build up the cross compiler on Ubuntu 64bits 14.04 in 2015

After settling up everything, I think it is beneficial to share the experience on the internet. I have reappeared all the mentioned steps in VirtualBOX with the same environment. TODO: What is OSEK? How is OSEK on NXT? I will revise the original tutorial and update all the out-date information/urls in the following concept. In fact, this article is also for me to record what I did within this suffering day... Refer from here -> Build and Install GNU ARM Install the required packages: ~$ sudo apt-get install tk-dev ncurses-dev libmpfr-dev texinfo And use the script file to build up the tool chain of cross compiler (ARMv7) wget http://lejos-osek.sourceforge.net/installation_linux_files/build_arm_toolchain.sh ~$ sh ./build_am_toolchain.sh You may need to use texinfo-4.13 to get rid of the error. wget http://ftp.gnu.org/gnu/texinfo/texinfo-4.13.tar.gz tar -xvf texinfo-4.13.tar.gz cd texinfo-4.13 ./configure sudo make install Afterwards, you can test the new gcc : "...

[Ubuntu/Windows] nxtOSEK / ticking block of NXT

In Windows 7: http://www.reddit.com/r/FTC/comments/1vvwq9/for_those_who_have_or_have_had_a_clicking_nxt/ I strongly recommend you to read this article, which really saves my life / 300 Euro! The critical point is that Windows 7 will automatically recognize the usb plug-in as bossa program, which is not available to excess as a NXT. All you have to do is to break down your internet and follow the steps in the article. [Quote] Plug in clicking nxt to computer Disable internet connection(very important) Open Device manager Under ports you should see Bossa program port, right click on it uninstall driver, on popup make sure to select delete from system (Don't forget to check the box that deleting all the installed driver) after uninstalling driver plug nxt into another port Because bossa driver is missing it should register as nxt brick Now you can reload Robotc firmware (with offical NXT software or NxTTool whatever) After firware installed reconnect internet Option ...

[RASP] VirtualBox Raspberry Pi debuging

This article is for the perspective that planning to debug Raspberry Pi connected to (Guest) Ubuntu Virtualbox with USBtoUART and Screen/terminal. There are two important issues that you may face: You cannot detect USB devices: You probably have a permission issue on your Virtual box. Add your user ID to group vboxusers with this command: sudo usermod -a -G vboxusers $USER , log off, log on and try again. http://askubuntu.com/questions/481693/virtualbox-usb-add-device-filter-does-not-work-under-14-04 You cannot listen the ttyUSB0: Your permission of (guest) account should be feasible to the ttyUSB0: sudo gedit /etc/group goto line... dialout:x:20: add your "username" dialout:x:20:username http://askubuntu.com/questions/40959/how-do-i-connect-to-tty-com-dev-ttyusb0 After that, then you can detect the plug-in usb on-the-fly or before open the virtual machine. Then, screen /dev/ttyUSB0 115200 (DON"T FORGET TO INSTALL VIRTUALBOX GUEST ADDITION PAC...

[LINUX] Hiding the source file and Linking the objects file

In order to prepare the exercise for students in RTEMS on Raspberry Pi, I dig into Makefile (which is auto generated by automake) this week. (The way to build up the example in RTEMS on Raspberry Pi : here ) The perspective of exercise is to let the students adopt our library to design a simpler real-time application. However, I want to hide the source code of library, but let the framework of makefile still work well. That is, we have to exclude the data dependency from the auto generated makefile. Assume we already compile the essential object as the library and place it at Source code directory, i.e., "...../rtems-gpio/testsuites/samples/SEMAPHORE_TEST". If we open Build directory, i.e., "build-rtems-rpi-gpio/arm-rtems4.11/c/raspberrypi/testsuites/samples/SEMAPHORE_TEST", we can find a Makefile that is generated by using automake with Makefile.am in Source code directory. As the typical rule in Makefile framework, all the dependencies of object will be ...