* WalrusIRC

You need to have 5 posts and not be part of restricted usergroups in order to use the WalrusIRC embedded shoutbox. However, you can also access our IRC channel called #CodeWalrus via EFnet.

Author Topic: Using a Router to program and communicate with Atmel AVRs  (Read 4123 times)

0 Members and 1 Guest are viewing this topic.

Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
Using a Router to program and communicate with Atmel AVRs
« on: May 07, 2015, 12:13:15 am »
I bought myself a Netgear WNR2200 Router. Not that I need it for it's original purpose, but it is a quite advanced little Linux computer with Wifi and USB actually.
It also has 4 MB Flash for the kernel (you can still use USB with overlay ext4 or fat32 fs to expand up to 32 GB or even more). I built my own firmware for it, which is based on the same Linux distribution as the stock one: OpenWrt.
I am using the trunk version Chaos Calmer which works great on this model, although I needed to patch some files to get it working.
I compiled USB drivers, got the USB chip working and included avrdude (only on overlay fs right now), gcc (overlay fs) and some usb serial FTDI drivers.
I am playing with the idea of letting the router (which I set to client mode wifi), connect to an Arduino / Atmel ATmega chip to get linux and web capabilities.
The router is (as far is I know) more powerful than the Arduino Yun and also a lot cheaper. I bought the router from amazon as used. It was one product that has already been opened but then sent back. It is alright, only the packaging was damaged.

I hope this is somehow useful.
Greetings, Benedikt
« Last Edit: September 26, 2016, 04:57:16 pm by DarkestEx »


  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

Offline Snektron

  • Lvl 69 Russian Snake
  • CodeWalrus Staff
  • Super User
  • Topic Management
  • Join Date: Dec 2014
  • Location: Netherlands
  • Posts: 3165
  • Post Rating Ratio: +32/-0
  • SSSssssss.....
    • RobinDeWalvis
    • Kzyrox
    • RobinDeWalvis
    • quantuminfinity
  • Gender: Male
whoa thats cool, i didn't know Routers ran on Linux :o Maybe i can hack into my own router which we dont use anymore the same way...
  • Calculators owned: TI-84+
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
whoa thats cool, i didn't know Routers ran on Linux :o Maybe i can hack into my own router which we dont use anymore the same way...
I am sure thats possible.
You should really try it.
Just ask me if you need any help.
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

Online xlibman

  • Omni founder & CW co-founder
  • Super User
  • Original 5
  • CodeWalrus Supporter
  • *
  • Join Date: Nov 2014
  • Location: Quebec, Canada
  • Posts: 18727
  • Post Rating Ratio: +95/-4
    • dj_omnimaga
    • DJOmnimaga.music
    • @DJOmnimaga
    • dj_omnimaga
    • @DJOmnimaga
    • /u/DJ_Omnimaga
    • DJOmnimaga
    • 112/11286
    • @djomnimaga
    • @DJOmnimaga
    • DJ Omnimaga music store
  • Gender: Male
Wait, does a router have a CPU? I am curious about how well it could run actual softwares such as a small game or text displaying routine?
  • Calculators owned: TI-57, 73, TI-80 (broken), TI-81, TI-82, TI-83, TI-83+ (broken), TI-83+ (broken), TI-83+SE (broken), TI-84+, TI-84+CSE, TI-84+CE, TI-85, TI-86, TI-89T, TI-92, TI-Nspire, TI-Nspire CX (semi-broken), HP 39gII, HP Prime, Casio fx-7000G, fx-7400G+, fx-7700GE, fx-9750G+, fx-9750GII, fx-9860G, cfx-9850G, FX-1.0+, fx-CG10, fx-CP400
  • Consoles, mobile devices and vintage computers owned: Samsung i5510, Nexus 5, Atari 2600, Lynx, SMS, Game Gear, Genesis, Dreamcast, NES, SNES, N64, GCN, Wii, Wii U, GBA, DS, 3DS, PS2, PS3, PS4, PSP, PSVita, XBox 360, XBOne

Bandcamp|Reverbnation|Facebook|Youtube|Twitter
Retired Omnimaga admin (2001-11) and editor (2012-14)

Offline Snektron

  • Lvl 69 Russian Snake
  • CodeWalrus Staff
  • Super User
  • Topic Management
  • Join Date: Dec 2014
  • Location: Netherlands
  • Posts: 3165
  • Post Rating Ratio: +32/-0
  • SSSssssss.....
    • RobinDeWalvis
    • Kzyrox
    • RobinDeWalvis
    • quantuminfinity
  • Gender: Male
Well appearantly it has. I haven't really though about it before though...
Also i think it would be quite well, considering you probably need a few hundred Mhz to run such a thing
  • Calculators owned: TI-84+
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


Offline Duke "Tape" Eiyeron

  • Urist McEiyolobster
  • Super User
  • Join Date: Nov 2014
  • Location: (V)(-_(//));(V)
  • Posts: 1636
  • Post Rating Ratio: +11/-2
  • Fanciest Walrus of the oceans.
    • @@Eiyeron
    • Eiyeron
    • /u/Eiyeron
    • Eiyeron
    • Rétro-Actif : Rétro/Prog/Blog
  • Gender: Male
A router does have a system (at least the high-end ones) to manage filtering, groups and redistribution. I remember in class having to use minicom to communicate to a router to configure it. I remember well this exercise becaus my glasses broke just before an eight-hour work. Cue headache after 20 minutes.
  • Calculators owned: A lot.

Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
Wait, does a router have a CPU? I am curious about how well it could run actual softwares such as a small game or text displaying routine?
Yes it does ;)
Think about it: These things need to deliver gigabit Ethernet and do WLAN, so they need some kind of processor and OS to handle all this.
Most routers run Linux as their OS, but some do run a proprietary RTOS.

E.g. the router I'm using in this case (Netgear WNR2200) has following specs:
CPU: Atheros AR7241 (MIPS architecture) @ 360 MHz
RAM: 64 Mb
Flash: 8 Mb
Interfaces: 1x USB 2.0, 5x Ethernet (1x WAN + 4x LAN @ 100 Mbit/s), Wifi (IC: AR9287, bgn, Host + Client Mode), JTAG, Serial, SPI
I/O: ~22 LEDs, 3 Buttons, and possibly more GPIO inside
Image:
(click to show/hide)

Yes, it certainly is able to run a terminal game over SSH.
It could probably even drive an LCD or using another PC as an X11 server and run a graphics game.
« Last Edit: May 09, 2015, 09:16:33 pm by DarkestEx »
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

Offline Streetwalrus

  • Professional slacker
  • Super User
  • Original 5
  • Join Date: Nov 2014
  • Location: Israel
  • Posts: 2903
  • Post Rating Ratio: +20/-0
  • ƎW∀⅁ ƎH⊥
  • Gender: Male
Some routers run some kind of BSD too. pfSense is based on freebsd and is another custom router firmware.
  • Calculators owned: TI-80, HP 40G, TI-84 Plus rev G (yay 128k RAM), TI-83 Plus Silver Edition (broken LCD), TI-82 Stats.fr (black), TI-Nspire CX rev C (yay Nlaunchy), TI-83+ SE ViewScreen



Online xlibman

  • Omni founder & CW co-founder
  • Super User
  • Original 5
  • CodeWalrus Supporter
  • *
  • Join Date: Nov 2014
  • Location: Quebec, Canada
  • Posts: 18727
  • Post Rating Ratio: +95/-4
    • dj_omnimaga
    • DJOmnimaga.music
    • @DJOmnimaga
    • dj_omnimaga
    • @DJOmnimaga
    • /u/DJ_Omnimaga
    • DJOmnimaga
    • 112/11286
    • @djomnimaga
    • @DJOmnimaga
    • DJ Omnimaga music store
  • Gender: Male
Wait, does a router have a CPU? I am curious about how well it could run actual softwares such as a small game or text displaying routine?
Yes it does ;)
Think about it: These things need to deliver gigabit Ethernet and do WLAN, so they need some kind of processor and OS to handle all this.
Most routers run Linux as their OS, but some do run a proprietary RTOS.

E.g. the router I'm using in this case (Netgear WNR2200) has following specs:
CPU: Atheros AR7241 (MIPS architecture) @ 360 MHz
RAM: 64 Mb
Flash: 8 Mb
Interfaces: 1x USB 2.0, 5x Ethernet (1x WAN + 4x LAN @ 100 Mbit/s), Wifi (IC: AR9287, bgn, Host + Client Mode), JTAG, Serial, SPI
I/O: ~22 LEDs, 3 Buttons, and possibly more GPIO inside
Image:
(click to show/hide)

Yes, it certainly is able to run a terminal game over SSH.
It could probably even drive an LCD or using another PC as an X11 server and run a graphics game.
Can it run DOOM? O.O
  • Calculators owned: TI-57, 73, TI-80 (broken), TI-81, TI-82, TI-83, TI-83+ (broken), TI-83+ (broken), TI-83+SE (broken), TI-84+, TI-84+CSE, TI-84+CE, TI-85, TI-86, TI-89T, TI-92, TI-Nspire, TI-Nspire CX (semi-broken), HP 39gII, HP Prime, Casio fx-7000G, fx-7400G+, fx-7700GE, fx-9750G+, fx-9750GII, fx-9860G, cfx-9850G, FX-1.0+, fx-CG10, fx-CP400
  • Consoles, mobile devices and vintage computers owned: Samsung i5510, Nexus 5, Atari 2600, Lynx, SMS, Game Gear, Genesis, Dreamcast, NES, SNES, N64, GCN, Wii, Wii U, GBA, DS, 3DS, PS2, PS3, PS4, PSP, PSVita, XBox 360, XBOne

Bandcamp|Reverbnation|Facebook|Youtube|Twitter
Retired Omnimaga admin (2001-11) and editor (2012-14)

Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
Wait, does a router have a CPU? I am curious about how well it could run actual softwares such as a small game or text displaying routine?
Yes it does ;)
Think about it: These things need to deliver gigabit Ethernet and do WLAN, so they need some kind of processor and OS to handle all this.
Most routers run Linux as their OS, but some do run a proprietary RTOS.

E.g. the router I'm using in this case (Netgear WNR2200) has following specs:
CPU: Atheros AR7241 (MIPS architecture) @ 360 MHz
RAM: 64 Mb
Flash: 8 Mb
Interfaces: 1x USB 2.0, 5x Ethernet (1x WAN + 4x LAN @ 100 Mbit/s), Wifi (IC: AR9287, bgn, Host + Client Mode), JTAG, Serial, SPI
I/O: ~22 LEDs, 3 Buttons, and possibly more GPIO inside
Image:
(click to show/hide)

Yes, it certainly is able to run a terminal game over SSH.
It could probably even drive an LCD or using another PC as an X11 server and run a graphics game.
Can it run DOOM? O.O
Probably yes :P
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

Offline Snektron

  • Lvl 69 Russian Snake
  • CodeWalrus Staff
  • Super User
  • Topic Management
  • Join Date: Dec 2014
  • Location: Netherlands
  • Posts: 3165
  • Post Rating Ratio: +32/-0
  • SSSssssss.....
    • RobinDeWalvis
    • Kzyrox
    • RobinDeWalvis
    • quantuminfinity
  • Gender: Male
I guess we have a challenge for you, Darkest :P
  • Calculators owned: TI-84+
Legends say if you spam more than DJ Omnimaga, you will become a walrus...


Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
I guess we have a challenge for you, Darkest :P
Challenge accepted!
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
Re: Using a Router to play DOOM?!
« Reply #12 on: May 13, 2015, 03:25:12 pm »
Wooha, that would cost me 22€ for the TFT.  O.O
As soon as I can confirm that I have access to the hardware SPI, I will go ahead and buy the TFT.
« Last Edit: May 13, 2015, 03:27:42 pm by DarkestEx »
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

Online xlibman

  • Omni founder & CW co-founder
  • Super User
  • Original 5
  • CodeWalrus Supporter
  • *
  • Join Date: Nov 2014
  • Location: Quebec, Canada
  • Posts: 18727
  • Post Rating Ratio: +95/-4
    • dj_omnimaga
    • DJOmnimaga.music
    • @DJOmnimaga
    • dj_omnimaga
    • @DJOmnimaga
    • /u/DJ_Omnimaga
    • DJOmnimaga
    • 112/11286
    • @djomnimaga
    • @DJOmnimaga
    • DJ Omnimaga music store
  • Gender: Male
Not bad I guess. :D
  • Calculators owned: TI-57, 73, TI-80 (broken), TI-81, TI-82, TI-83, TI-83+ (broken), TI-83+ (broken), TI-83+SE (broken), TI-84+, TI-84+CSE, TI-84+CE, TI-85, TI-86, TI-89T, TI-92, TI-Nspire, TI-Nspire CX (semi-broken), HP 39gII, HP Prime, Casio fx-7000G, fx-7400G+, fx-7700GE, fx-9750G+, fx-9750GII, fx-9860G, cfx-9850G, FX-1.0+, fx-CG10, fx-CP400
  • Consoles, mobile devices and vintage computers owned: Samsung i5510, Nexus 5, Atari 2600, Lynx, SMS, Game Gear, Genesis, Dreamcast, NES, SNES, N64, GCN, Wii, Wii U, GBA, DS, 3DS, PS2, PS3, PS4, PSP, PSVita, XBox 360, XBOne

Bandcamp|Reverbnation|Facebook|Youtube|Twitter
Retired Omnimaga admin (2001-11) and editor (2012-14)

Offline DarkestEx

  • Super User
  • Join Date: Jan 2015
  • Location: Germany
  • Posts: 1324
  • Post Rating Ratio: +10/-2
    • @0xbmuessig
    • @muessigb
    • My homepage
  • Gender: Male
So I think that I will make a WiFi music player with an LCD out of it.
That will probably be the best thing to do with it. The doom thing will have to wait.
  • Calculators owned: TI-84+, Casio 101-S, RPN-Calc, Hewlett-Packard 100LX, Hewlett-Packard 95LX
  • Consoles, mobile devices and vintage computers owned: Hewlett-Packard 100LX, Hewlett-Packard 95LX, Original Commodore 64C, Tektronix AWG2021, IBM X60s, IBM X60t, Nintendo DS Lite, Nintendo GameBoy Color, Nintendo GameCube, Xbox 360, Palm m5


Avatar drewn for me by Tabbes.

 


You can also use the following HTML or bulletin board code to share it on your page or forum signature!


Also do not forget to check our affiliates below.
Planet Casio TI-Planet Calc.news BroniesQC BosaikNet Velocity Games