Random Stuff and Updates on Works In Progress
by Demolishun · 05/08/2012 (1:07 pm) · 7 comments
Updates:
scriptT3D: scripting addon for T3DFirst just a short update. Well mostly just a link for my T3D extension to Python. Mostly I have cleaned up the code, removed old commented junk, and separated out the Python code from the generic code. This is a needed step to allow for future additions of other scripting languages. It also helped make the interface much easier to understand and maintain. Here is a link to a previous blog where I am tracking these changes:
T3D Scripting Extension
Random Junk:
Web StuffI am really starting to like using Code Igniter and JQuery together. They are a powerful combination. It is a lot of fun to make dynamic pages. I especially like the Code Igniter version of sessions. They are database transparent and do encryption with very little configuration. I was also able to shoehorn in a package that does integration with the major authorization sites: facebook, google, openid, etc. JQuery just makes the JS so much more useful and well designed.
Embedded Stuff
I am researching connecting a microcontroller to the T3D engine for some alternate inputs. I started looking for a lightweight protocol to handle the communication and finally I think I am going to settle on a variant of JSON. It is called the Universal Binary JSON Specification. There are other binary JSON specs out there, but I am going to choose this one because it more closely models the JSON spec, it is smaller in size than regular JSON, and does not require conversion from text to binary formats inside the microcontroller. It also allows for simple messages to be sent from the microcontroller without conversion to text. This is very important when running code on a device that runs at 16MHz. I will have to add simple error checking using a checksum, but the protocol itself will be JSON like. Another part of this project is to connect to an Android phone, however phone companies are damaging the Bluetooth on newer phones. Most carriers are making it difficult to use Bluetooth devices other than head sets on the phones. I had to change the firmware on my phone to compensate. One route around this is to have a computer connect to the microcontroller through Bluetooth, and have the Android phone connect to a network port on the computer. It does add a computer in the mix, but it would be a workable solution to phone vendors breaking Bluetooth functionality.
ARM Stuff
Part of one of my projects is looking into using an ARM based device (or cheap embedded device) to connect to a some hardware for use in biometrics. I have found that China is producing some really interesting devices and you can get a Wifi enabled ARM platform with Android for $80 to $200 and up for better devices. This is really exciting as it could potentially be a non-phone related market for games and applications. After my recent discovery of phone makers breaking functionality this is a welcome market trend. If someone cannot use their phone for a particular application then you may be able to point a customer to a well built Android platform for about a $100. When phones are supposedly costing $500 or more without a plan, then this opens up the Android market quite a bit. It is definitely something to keep ones eye on.
End of Rant:
Well that is it for now. That sums up a lot of other things I have been working on. I have been trying to find a way to tie these into my other blogs, but there was just not enough common links. Hence the random dump of topics. These topics actually do tie in together in one project, however, that is for another blog. Yep, that was a blog "teaser". ;)About the author
I love programming, I love programming things that go click, whirr, boom. For organized T3D Links visit: http://demolishun.com/?page_id=67
#2
It will never replace TS unless I go for an interpreter change internal to the engine. I am mainly treating T3D as a black box with external scripting language hooks. I am not sure how different T2D is from T3D, but when I release the resource for this then if your game you could check out the addition. I am using SWIG to help with the interface and I think it supports Ruby as well. It will take some effort to add the interface functions, but it is doable. I am hoping the community will pick it up and add support for things they want in the interface. However, I really need to get the support scripting in Python to a mature state so people can see the value. I don't see JavaScript support in SWIG, but they do support a lot of scripting languages.
I am mainly using JSON as a transport between a microcontroller and a computer. I need to get the data to T3D somehow and the binary JSON implementation makes it less CPU intensive. There are not really any main stream binary versions of JSON. I think the app I am working on may be a good catalyst.
The reason phone companies are modifying the bluetooth stacks is to prevent functionality that either costs them bandwidth, or are part of features or products they want to charge more for. In my case I wanted to connect an SPP (serial port) device to my phone so I could transfer data to the phone for use in an app. However, the SPP profile could be used to use the phone as a modem is my guess. Although, it also blocked my using a Wii with my phone. I am guessing there that they only include specific bluetooth profiles they want to be on the phone. The solution was: rooting the phone and backing up the phone using the Clockwork recovery program, installing a program called Boot Manager (I recommend the paid version), and installing a different firmware using the Boot Manger. Make sure on the firmwares that you install the Google Apps using the Boot Manager from the main firmware if you do this. Otherwise you may be having to restore from your Clockwork backup. Also, DO NOT DO THIS IF YOU HAVE NOT BACKED UP YOUR PHONE. My backup is the Clockwork program. I don't want anybody who is iffy on technical stuff bricking their phone and being mad about it. :)
Yeah, it is way different at the small microcontroller level. I don't think this reply would fit in the ram of the processor. I still have an Apple IIgs. I was thinking about giving it a USB host interface and having it boot from a flash drive. That would be a kick in the pants.
The goal started out as wanting to be able to use Python with T3D. Then I thought I could use it to parallelize processes for lots of AI and doing simulation runs which require lots of power. Now, I still will use it for those reasons, but I wanted to make it be extendable and be useable by the GG community. That last part is making me document the code better and clean up the interfaces to make it a maintainable project. I use Python a lot for my consulting business and I really love the language. On a given day I will use Python, Javascript, PHP, HTML, C++, and C. I still prefer writing things in Python even though I learned C/C++ first. Torque Script is fine as an engine language and I am not working to replace it. However, I find Python much more efficient and feature rich than TS. The other part of this was learning SWIG to support my other customers needing specialized code for Pyhon. Now I have a really good grasp of SWIG I can use it in future projects.
So I guess the goal is to make a really cool engine (T3D) be able to be programmed in a really cool language (Python). SWIG supporting other languages is just gravy on top and makes sense to try and structure the code to support additions in the future. Yes, I have a specific project I am using this for and having Python available will help.
05/09/2012 (12:12 pm)
@Charlie,It will never replace TS unless I go for an interpreter change internal to the engine. I am mainly treating T3D as a black box with external scripting language hooks. I am not sure how different T2D is from T3D, but when I release the resource for this then if your game you could check out the addition. I am using SWIG to help with the interface and I think it supports Ruby as well. It will take some effort to add the interface functions, but it is doable. I am hoping the community will pick it up and add support for things they want in the interface. However, I really need to get the support scripting in Python to a mature state so people can see the value. I don't see JavaScript support in SWIG, but they do support a lot of scripting languages.
I am mainly using JSON as a transport between a microcontroller and a computer. I need to get the data to T3D somehow and the binary JSON implementation makes it less CPU intensive. There are not really any main stream binary versions of JSON. I think the app I am working on may be a good catalyst.
The reason phone companies are modifying the bluetooth stacks is to prevent functionality that either costs them bandwidth, or are part of features or products they want to charge more for. In my case I wanted to connect an SPP (serial port) device to my phone so I could transfer data to the phone for use in an app. However, the SPP profile could be used to use the phone as a modem is my guess. Although, it also blocked my using a Wii with my phone. I am guessing there that they only include specific bluetooth profiles they want to be on the phone. The solution was: rooting the phone and backing up the phone using the Clockwork recovery program, installing a program called Boot Manager (I recommend the paid version), and installing a different firmware using the Boot Manger. Make sure on the firmwares that you install the Google Apps using the Boot Manager from the main firmware if you do this. Otherwise you may be having to restore from your Clockwork backup. Also, DO NOT DO THIS IF YOU HAVE NOT BACKED UP YOUR PHONE. My backup is the Clockwork program. I don't want anybody who is iffy on technical stuff bricking their phone and being mad about it. :)
Yeah, it is way different at the small microcontroller level. I don't think this reply would fit in the ram of the processor. I still have an Apple IIgs. I was thinking about giving it a USB host interface and having it boot from a flash drive. That would be a kick in the pants.
The goal started out as wanting to be able to use Python with T3D. Then I thought I could use it to parallelize processes for lots of AI and doing simulation runs which require lots of power. Now, I still will use it for those reasons, but I wanted to make it be extendable and be useable by the GG community. That last part is making me document the code better and clean up the interfaces to make it a maintainable project. I use Python a lot for my consulting business and I really love the language. On a given day I will use Python, Javascript, PHP, HTML, C++, and C. I still prefer writing things in Python even though I learned C/C++ first. Torque Script is fine as an engine language and I am not working to replace it. However, I find Python much more efficient and feature rich than TS. The other part of this was learning SWIG to support my other customers needing specialized code for Pyhon. Now I have a really good grasp of SWIG I can use it in future projects.
So I guess the goal is to make a really cool engine (T3D) be able to be programmed in a really cool language (Python). SWIG supporting other languages is just gravy on top and makes sense to try and structure the code to support additions in the future. Yes, I have a specific project I am using this for and having Python available will help.
#3
I nearly wet my pants, Frank! Do you mean, like an Arduino?
And with this, SkyNet is born...
On a serious note, good to see you're enjoying yourself Frank, and that you're getting things done.
05/09/2012 (6:46 pm)
Quote:I am researching connecting a microcontroller to the T3D engine for some alternate inputs.
I nearly wet my pants, Frank! Do you mean, like an Arduino?
Quote:Part of one of my projects is looking into using an ARM based device (or cheap embedded device) to connect to a some hardware for use in biometrics. I have found that China is producing some really interesting devices and you can get a Wifi enabled ARM platform with Android for $80 to $200 and up for better devices.
And with this, SkyNet is born...
On a serious note, good to see you're enjoying yourself Frank, and that you're getting things done.
#4
Ummm...well...you might want to get a towel or something, but yes like an Arduino. I found a nice Arduino with BT from Iteaduino for $38 instead of $120. It works very well. I also found a source of BT modules for less than $10 a pop. Iteaduino also has a nice Arm based device that runs at 120Mhz for more advanced tasks. It does take a while to get items from them as they are located in China, but the quality and support is good.
Skynet is...well...only one piece of the puzzle Dr. Breen and myself are working on. Dan, have you ever thought of "upgrades"? We do need some test subj...erm...volunteers for a low risk implant or two... Seriously, the cat was fine...mostly.
Yep, it has been like walking through a fog the last few months, but things are looking much clearer now. It has started to get to the fun stuff.
05/09/2012 (8:02 pm)
@Dan,Ummm...well...you might want to get a towel or something, but yes like an Arduino. I found a nice Arduino with BT from Iteaduino for $38 instead of $120. It works very well. I also found a source of BT modules for less than $10 a pop. Iteaduino also has a nice Arm based device that runs at 120Mhz for more advanced tasks. It does take a while to get items from them as they are located in China, but the quality and support is good.
Skynet is...well...only one piece of the puzzle Dr. Breen and myself are working on. Dan, have you ever thought of "upgrades"? We do need some test subj...erm...volunteers for a low risk implant or two... Seriously, the cat was fine...mostly.
Yep, it has been like walking through a fog the last few months, but things are looking much clearer now. It has started to get to the fun stuff.
#5
05/10/2012 (10:59 pm)
Mention robots, cybernetics or lasers and I turn into a slavering mess. That is to say, where do I sign up?
#6
I am building 2 robots: one swimmer, and one crawler to inspect large tanks for our robotics company. Completely unrelated to the above work, but that is one of the things I am working on. The swimmer is based upon the Video Ray series of swimming robots, and the crawler is a custom 200lb robot that we built. The crawler is very mean. We have an extra shell we have not committed yet, and we have talked about seeing if we can enter a robot contest in the future. Right now though, we have to get our company solvent first.
At some point I want to explore some of my own theories for communicating with a computer by pure thought. I have examined a lot of the ways neural scientists are attempting to do this. However, I find their ideas lacking. The best examples I have seen so far is monitoring electrical pulses to actuate artificial limbs. However, this is only making use of pulses that were designed originally to move the limbs they lost. True integration will be the brain learning to control equipment or computers with both sides of the equation adapting and creating the interface. The brain must, at some point, learn to use the interface and even form new neural pathways. At least that is my opinion of what is missing in cybernetics.
Ummm...llllaaaaaazzzzerrrrr...
05/11/2012 (12:06 am)
@Dan,I am building 2 robots: one swimmer, and one crawler to inspect large tanks for our robotics company. Completely unrelated to the above work, but that is one of the things I am working on. The swimmer is based upon the Video Ray series of swimming robots, and the crawler is a custom 200lb robot that we built. The crawler is very mean. We have an extra shell we have not committed yet, and we have talked about seeing if we can enter a robot contest in the future. Right now though, we have to get our company solvent first.
At some point I want to explore some of my own theories for communicating with a computer by pure thought. I have examined a lot of the ways neural scientists are attempting to do this. However, I find their ideas lacking. The best examples I have seen so far is monitoring electrical pulses to actuate artificial limbs. However, this is only making use of pulses that were designed originally to move the limbs they lost. True integration will be the brain learning to control equipment or computers with both sides of the equation adapting and creating the interface. The brain must, at some point, learn to use the interface and even form new neural pathways. At least that is my opinion of what is missing in cybernetics.
Ummm...llllaaaaaazzzzerrrrr...
#7
Sounds like you're doing awesome things there, Frank. Good luck with the haptic interface thing.
05/11/2012 (3:43 am)
See, I want to mesh video gaming with Robot Wars and Laser Force (where people shoot each other with lasers and score it). You can control the bots via the 'net and shoot other bots on an actual course. That has actual people sitting around it, watching and/or betting. Can I borrow your crawler?Sounds like you're doing awesome things there, Frank. Good luck with the haptic interface thing.

Associate Charlie Patterson
Default Studio Name
Do you have a specific goal for all your work on alternate scripting languages?
At this point, I've got too much TorqueScript code to switch, but my pet language for scripting is Ruby. :) The language I think will take over most scripting soon enough? JavaScript.
JSON and TorqueScript have a few natural similarites. But TS has a few more limitations, I think, because you can't naturally create complex structures, for instance, SimObjects inside of SimObjects.
Why are phone companies blocking bluetooth, do you think?
Ah, the good ol' days of 16MHz. I remember the Commodore 64 having 900Khz. :)