NEW PROJECT :-)

Here you can discuss things that are not directly related to running or using XBMC4XBOX.
Post Reply
User avatar
professor_jonny
Posts: 1296
Joined: Thu Jul 05, 2012 5:41 am
Location: New Zealand
Has thanked: 66 times
Been thanked: 196 times

NEW PROJECT :-)

Post by professor_jonny »

After xphazer was having a play with the audrino I thaught of knocking up a diagram for a possible inplemtation of an lcd and stereo amberlight using a micro on i2c.

I dont know if the i2c port in the xbox would have enough bus space free to implement it but this would make a good setup specific to the xbox and includes debug and bootloader restore and conversion for the 3.3v i2c port on the xbox to 5volt micro levels:
The screen would be provided by bit banging the hardware and providing a second i2c master port for direct adressing an lcd and stereo amberlight with the ability to drive 10 amps.

Most of the code for this would be in public domain it is just a matter of stitching it all together.
Untitled.jpg
fxmech
Posts: 673
Joined: Wed Aug 01, 2012 9:15 am
Has thanked: 37 times
Been thanked: 46 times

Re: NEW PROJECT :-)

Post by fxmech »

Intrigued
User avatar
GhostlyGamer
Posts: 356
Joined: Sun Jul 15, 2012 5:34 am
Location: Seattle USA
Has thanked: 16 times
Been thanked: 15 times

Re: NEW PROJECT :-)

Post by GhostlyGamer »

Id like to see where this goes. Could be interesting and a cheap new LCD system.
Image
Image
User avatar
professor_jonny
Posts: 1296
Joined: Thu Jul 05, 2012 5:41 am
Location: New Zealand
Has thanked: 66 times
Been thanked: 196 times

Re: NEW PROJECT :-)

Post by professor_jonny »

i actually found something for this exzact project on the net recently that requires minimal effort from a hardware side that needs adapting slightly for the xbox.

I did mess with it with my satellite decoder using modprobe at one stage as it runs linux.

ill post when I get back home it is for an with the audrino uno using 24 rgb led's connected to a host pc via usb to control the led's.

It just needs converting to i2c as oposed to usb using the bit bang library as the onboard spi bus is used for the rgb led's.

Basically the pc sends out 24 numbers over usb one for each led representing a number between 0 and 255 which denotes the colour and it latches until it recieves another colour or a blank.

from the xbox side it needs to decode an average colour for each led and the code for this is available for the pc. but this may slow down the xbox :-(

I believe one of the mod chips sends the data over the i2c bus and this will need to be modified from the xbox side to match the rgb protocol of the source code as it is a lot more feature packed compaired to the smartxx protocol.

The lcd is a lot harder to acomplish, beyond my skills as it requires a buffer as the bus is used for other things and the icd works over the lcp bus I believe and more complex protocol.
User avatar
professor_jonny
Posts: 1296
Joined: Thu Jul 05, 2012 5:41 am
Location: New Zealand
Has thanked: 66 times
Been thanked: 196 times

Re: NEW PROJECT :-)

Post by professor_jonny »

This is the project I was looking at it saves making a circuit board and all that stuff:

http://learn.adafruit.com/adalight-diy- ... v-lighting

and all the code for the windows and audrino is here:

https://github.com/adafruit/Adalight.

the software transmits the code captured from the pc and sends it to the audrino over a usb serial connection.

the code is in java on a second look so importing it into xbmc code may be harder but it looks rater simple it would be nice if mainstream put something like this into their code :-)
psyko_chewbacca
Posts: 213
Joined: Fri Oct 05, 2012 5:19 pm
Location: Québec, Canada
Has thanked: 21 times
Been thanked: 125 times

Re: NEW PROJECT :-)

Post by psyko_chewbacca »

I'm not sure if it applies specifically to the Xbox but isn't SMBus max frequency like 100KHz? I don't think it would be fast enough to implement character LCD support and a 6 channels Ambilight clone at the same time. At least the refresh rate of both device would be somewhat slow if you take into account that the SMBus already have some traffic from the Xbox system itself.

I would go through LPC for this. 33MHz, 4-bit wide and a lot of spare bandwitdh once the BIOS has been transferred (if you use a modchip). All would be needed is a LPC mod with the necessary hardware to output the desired data.

Of course an ATMEGA168 would not be fast enough to capture data at 33MHz but there are alternatives.

I might have some interesting things to share in the coming weeks regarding the LPC bus. I'll post an update when the time comes.
User avatar
professor_jonny
Posts: 1296
Joined: Thu Jul 05, 2012 5:41 am
Location: New Zealand
Has thanked: 66 times
Been thanked: 196 times

Re: NEW PROJECT :-)

Post by professor_jonny »

the problem with the LCP bus is you really need a clpd to be fast enough. and I cant program them i have one and a jtag cable but no knowlege in macro logic programming.

a fast micro would do but you would need to bit bang an lcp bus interface on it for the xbox, I have yet to come across a sample code for that.

i2c is alread implemented and easy to use and heaps of tools available. if the lcd is updated every second if the bus could shurly handle that using the interface chip as a buffer.

for the amberlight project with rgb you are looking at 24 sections with a colour and intensity value that is 24 strings of data per refersh and a refersh of whatever per second.

it might be pushing it.

the sample code around for clpd is not for bus master as used in the xbox.
psyko_chewbacca
Posts: 213
Joined: Fri Oct 05, 2012 5:19 pm
Location: Québec, Canada
Has thanked: 21 times
Been thanked: 125 times

Re: NEW PROJECT :-)

Post by psyko_chewbacca »

professor_jonny wrote:the problem with the LCP bus is you really need a clpd to be fast enough. and I cant program them i have one and a jtag cable but no knowlege in macro logic programming.

a fast micro would do but you would need to bit bang an lcp bus interface on it for the xbox, I have yet to come across a sample code for that.

i2c is alread implemented and easy to use and heaps of tools available. if the lcd is updated every second if the bus could shurly handle that using the interface chip as a buffer.

for the amberlight project with rgb you are looking at 24 sections with a colour and intensity value that is 24 strings of data per refersh and a refersh of whatever per second.

it might be pushing it.

the sample code around for clpd is not for bus master as used in the xbox.
I agree that using the I2C for LCD is feasible with a low refresh rate. I wonder why it wasn't done earlier anyway.

LPC communication is not really hard to understand. Intel provides a LPC spec PDF that describes really well how it works. There is already logic in XBMC to drive the LPC bus. Maybe a look at the source code could help understand how the LPC bus works.
User avatar
professor_jonny
Posts: 1296
Joined: Thu Jul 05, 2012 5:41 am
Location: New Zealand
Has thanked: 66 times
Been thanked: 196 times

Re: NEW PROJECT :-)

Post by professor_jonny »

The matrix mod chip reads the lcd data off i2c already but it is buffered and redirected out over one of the spi interfaces on the chip i believe it has two of them.
Post Reply