New Knight rider Flasher

Other Engineering Diciplines
RAT16F88
Lieutenant
Lieutenant
Posts: 72
Joined: Sat Nov 20, 2010 12:36 pm
Location: Inside a PIC

New Knight rider Flasher

Post by RAT16F88 » Sat Nov 27, 2010 11:55 pm

Code: Select all

char add;

void main() {
	PORTB = 0 ;
	TRISB = 0;

	while(1) {

	do{
		PORTB = (PORTB*2)+1;
		Delay_ms(100);
	}while(PORTB<254);

	if(PORTB = 255){
		do{
			PORTB = PORTB<<1;
			Delay_ms(100);
		}while(PORTB >0);
	}

	Delay_ms(300);
	add = 128;

	do{
		PORTB = PORTB + add;
		Delay_ms(100);
		add = add/2;
	}while(PORTB<255);

	if(PORTB = 255){
		do{
			PORTB = PORTB>>1;
			Delay_ms(100);
			}while(PORTB >0);
		}
		Delay_ms(300);
	}
}
rat.jpg
rat.jpg (29.48 KiB) Viewed 14126 times
Last edited by Neo on Thu Jul 21, 2011 6:54 am, edited 8 times in total.
Reason: Enabled syntax highlighting with syntax=c & re-added indents with TAB / Added resized image
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Re: New Knight rider Flasher

Post by Neo » Sun Nov 28, 2010 2:35 am

Cool. If you can add some photos of the circuit design and demo with code, it would even be more useful.
Keep up the good work!
RAT16F88
Lieutenant
Lieutenant
Posts: 72
Joined: Sat Nov 20, 2010 12:36 pm
Location: Inside a PIC

Re: New Knight rider Flasher

Post by RAT16F88 » Sun Nov 28, 2010 9:02 pm

[media]http://www.youtube.com/watch?v=46xHQsZqRLM[/media]
User avatar
Nipuna
Moderator
Moderator
Posts: 2729
Joined: Mon Jan 04, 2010 8:02 pm
Location: Deraniyagala,SRI LANKA

Re: New Knight rider Flasher

Post by Nipuna » Sun Nov 28, 2010 10:31 pm

Hey So Cool

I was searching a Knight Rider Circuit Like this. But all the Circuits that Shops have only one way or Center to two way Lighting Ones.

First time I saw circuit like this. Just as I thought :)

But I want be able to make one like that because fist i have to learn programing then I'll try to make Micro controller stuff.
But My Problem is i don't have time even to learn programing because of my Freelancer works.
Now I am Planning to Stop them a while and Start learning. and do freelancing as Part time. :)


Thanks
RAT16F88
Lieutenant
Lieutenant
Posts: 72
Joined: Sat Nov 20, 2010 12:36 pm
Location: Inside a PIC

Re: New Knight rider Flasher

Post by RAT16F88 » Mon Nov 29, 2010 12:16 am

Yeah ,thanks Nipuna .
Programming microcontrollers(PICs only) is very easy but all you need is time to experiment
Every thing you need is in ROBOT.LK so good luck. :) :) :) :)
User avatar
Neo
Site Admin
Site Admin
Posts: 2642
Joined: Wed Jul 15, 2009 2:07 am
Location: Colombo

Re: New Knight rider Flasher

Post by Neo » Mon Nov 29, 2010 6:05 am

Rat,
This is very good. Really good encouragement for new guys to start on.
Sharing knowledge and experience for the benefit of the community is EC's vision....
Keep up the good work..
User avatar
Nipuna
Moderator
Moderator
Posts: 2729
Joined: Mon Jan 04, 2010 8:02 pm
Location: Deraniyagala,SRI LANKA

Re: New Knight rider Flasher

Post by Nipuna » Mon Nov 29, 2010 8:46 am

Thanks Friends
RAT16F88
Lieutenant
Lieutenant
Posts: 72
Joined: Sat Nov 20, 2010 12:36 pm
Location: Inside a PIC

Re: New Knight rider Flasher

Post by RAT16F88 » Mon Nov 29, 2010 1:34 pm

Neo wrote:Rat,
This is very good. Really good encouragement for new guys to start on.
Sharing knowledge and experience for the benefit of the community is EC's vision....
Keep up the good work..
Thanks Neo I'll try my best :) :) :)
User avatar
Enigma
Lieutenant
Lieutenant
Posts: 74
Joined: Sun Jan 16, 2011 12:40 am
Location: Colombo, Sri Lanka

Re: New Knight rider Flasher

Post by Enigma » Thu Jul 21, 2011 6:20 am

This is great RAT16. I'm Waiting till my exams get over. Yep. You are correct. ROBOT.LK got every thing we need to start MCU developments. :) :) :) :) :) :)
User avatar
Rksk
Major
Major
Posts: 730
Joined: Thu Jan 07, 2010 4:19 pm
Location: Rathnapura, Sri Lanka

Re: New Knight rider Flasher

Post by Rksk » Tue Aug 30, 2011 6:14 pm

Oh! forgot to tell that,

I tested above code 2days before and got below result.
[media]http://youtube.com/watch?v=Zblbgm8pLYg[/media]

It's 100% not match with above posted video by RaT.

Where is the wrong? does RaT lie?

[ Post made via Mobile Device ] Image
Post Reply

Return to “Other”