Sign up Calendar Latest Topics
 
 
 


Reply
  Author   Comment  
Sintax7

Registered:
Posts: 90
Reply with quote  #1 
It looks like there's great progress on the DMX side of things with Artemis.  Reading back through the prior threads theres been a few attempts to get data out of the "ship" without DMX.  I'm wondering the current status of those project(s)?

Specifically I want to have a semi-large 7-segment LED readout of the current energy-level of the ship.  

[digit2] 

Additionally weapon stores and other data could be display this way as well.  It could be done with a bunch of dmx channels per segment.  Maybe with a dmx level->converted to a single digit?  Best would likely be with an API or other 'hook' into the system and display through an arduino or Pi?

__________________
Lee A Keiser II - sintax7@gmail.com 
https://www.facebook.com/groups/simpitbuilder/
https://www.facebook.com/TheStarshipSimulator/
ivansanchez

Avatar / Picture

Registered:
Posts: 113
Reply with quote  #2 
Quote:
Originally Posted by Sintax7
Specifically I want to have a semi-large 7-segment LED readout of the current energy-level of the ship.

Best would likely be with an API or other 'hook' into the system and display through an arduino or Pi?


Well, if you go through the Development subforum, you'll see I'm developing Glitter, a Javascript client. And I'm perfectly able to read the energy level of any player ship at this point. I haven't tested it out on my Raspberry Pi, but there's nothing preventing to prevent Glitter from running in a Pi.

I've done a bit of research and found a couple of interesting things:
https://www.adafruit.com/products/1270 (a US$17.5 4-digit 7-segment display with i2c interface)
https://learn.adafruit.com/matrix-7-segment-led-backpack-with-the-raspberry-pi (How to wire the 4-digit display to the Pi)
https://github.com/kelly/node-i2c (How to send stuff through i2c from a node.js program)

If you (or anyone) makes a simple node.js program that controls such a 7-segment display, I can easily add it to Glitter.

__________________
Need more bling for your bridge? Try out Artemis-Glitter today!
Sintax7

Registered:
Posts: 90
Reply with quote  #3 
Ok.... Help me understand this a bit better...  How would the hardware flow for this?

The main machine for the ship runs Glitter and is connected through USB to maybe an arduino controller (I'm thinking the Nano v3.0 ATmega328P-20AU Board) which is then connected to one or more 7-segment displays?

How many independent readouts could Glitter feed?  Could it feed multiple controller boards or just one at a time?



__________________
Lee A Keiser II - sintax7@gmail.com 
https://www.facebook.com/groups/simpitbuilder/
https://www.facebook.com/TheStarshipSimulator/
ivansanchez

Avatar / Picture

Registered:
Posts: 113
Reply with quote  #4 
Quote:
Originally Posted by Sintax7
Ok.... Help me understand this a bit better...  How would the hardware flow for this?
So my idea is to run everything from just the RaspberryPi plus the adafruit 4-digit 7-segment display. The display I linked in my previous post is not just the LEDs: it actually includes a HT16K33 microcontroller which provides an i2c interface.
So you just need a Pi, and the display.
Then, hook up the four wires to the display: GND/3VCC to provide power, and SDL/SDA to the Pi's SDL0/SDA0 pins in the GPIO to provide control via i2c. Raspberry, display, four wires, that's it.
The raspberry would run a combination of node.js software: Glitter for connecting to an Artemis server via ethernet, and node-i2c to talk to the display. So:
Artemis server ---eth--- Raspberry Pi ---i2c--- (ht16k33 + 7-segment display)
Quote:
Originally Posted by Sintax7
How many independent readouts could Glitter feed?  Could it feed multiple controller boards or just one at a time?
I2C is actually a *bus*, so theoretically you could hook up about a hundred different displays and microcontrollers to the same SDL/SDA wires.

__________________
Need more bling for your bridge? Try out Artemis-Glitter today!
Sintax7

Registered:
Posts: 90
Reply with quote  #5 
So the Pi is just another ethernet device on the lan that is connecting the various computers together?  It polls or queries the main screen cpu for its info?
__________________
Lee A Keiser II - sintax7@gmail.com 
https://www.facebook.com/groups/simpitbuilder/
https://www.facebook.com/TheStarshipSimulator/
ivansanchez

Avatar / Picture

Registered:
Posts: 113
Reply with quote  #6 
Quote:
Originally Posted by Sintax7
So the Pi is just another ethernet device on the lan that is connecting the various computers together?  It polls or queries the main screen cpu for its info?


Yeah, that's the plan.

The Pi will run Glitter, which connects to the Artemis server (the computer with the main screen) and acts as a observer console.

__________________
Need more bling for your bridge? Try out Artemis-Glitter today!
Sintax7

Registered:
Posts: 90
Reply with quote  #7 
What can you tell me about the capabilities of the I2C bus?  Is there a resource / url that you'd recommend?
__________________
Lee A Keiser II - sintax7@gmail.com 
https://www.facebook.com/groups/simpitbuilder/
https://www.facebook.com/TheStarshipSimulator/
ivansanchez

Avatar / Picture

Registered:
Posts: 113
Reply with quote  #8 
Quote:
Originally Posted by Sintax7
What can you tell me about the capabilities of the I2C bus?  Is there a resource / url that you'd recommend?


I'd suggest reading http://www.instructables.com/id/Raspberry-Pi-I2C-Python/#step0.

As for capabilities, it allows you to control a number of low-power (3 volts) electronics, writing and reading bytes to them. I don't have a lot of experience with it, so I'll have to try stuff with my own RaspPi.



__________________
Need more bling for your bridge? Try out Artemis-Glitter today!
Previous Topic | Next Topic
Print
Reply

Quick Navigation:

Easily create a Forum Website with Website Toolbox.