quarta-feira, janeiro 12, 2011

Atualize seu Motorola Milestone para o Android 2.2 (Froyo) hoje mesmo em PORTUGUÊS DO BRASIL | rodrigostoledo.com

Atualize seu Motorola Milestone para o Android 2.2 (Froyo) hoje mesmo em PORTUGUÊS DO BRASIL | rodrigostoledo.com: "

Para quem tem pressa e não quer esperar pela atualização Oficial do Milestone da Motorola para o Android 2.2 (Froyo), vale a pena conferir o post do Richard Max, que transcrevo na íntegra a seguir. Vale lembrar que este procedimento só deve ser feito por usuários mais avançados, e que realmente sabem o que estão fazendo, que o procedimento utiliza ROMs originais, logo, não temos nenhuma pirataria por aqui, mas apesar de tudo, se algo der errado, provavelmente você perderá a garantia do seu aparelho celular, deste modo, faça sob sua conta e risco!!

“Apesar de eu nao ter encontrado problemas, algumas pessoas estão encontrando dificuldades com o 2.2, então estou colocando aqui as ROMS da TIM, VIVO e a RETAIL, para quem quiser voltar para a original.

O Procedimento é o mesmo ok? só refazer com a ROM 2.1

Versão RETAIL –SHLA_U2_03.05.0_USASHLSRETBRLA02C.0R_PDS002_USASHLSRETBRLAT_P029_A026_HWp2a_1FF.sbf.gz

Versão TIM –SHLA_U2_03.05.0_USASHLSTIMBRLA02C.0R_PDS002_USASHLSTIMBRLAT_P041_A036_HWp2a_1FF.sbf.gz

Versão VIVO –SHLA_U2_03.05.0_USASHLSVIVBRLA02D.0R_PDS002_USASHLSVIVBRLAT_P038_A027_HWp2a_1FF.sbf.gz

Pronto, quem quiser voltar para a 2.1 basta pegar a ROM correta. se for TIM pegue TIM, se for VIVO pegue VIVO, os demais peguem a RETAIL. sigam o mesmo tutorial apenas usem a ROM correta.

Meu aparelho funcionou sem problemas com OI, VIVO e TIM, mas no chip da OI, demorou uns 30 minutos para ele achar a rede e eu fiz manualmente antes. depois ele achou sem problemas.

Fim da atualização.

Olá amigos, sim isso mesmo, enquanto não sai a versão oficial brasileira do Froyo, já podemos ter o prazer de usar em nosso aparelho com a ROM canadense.

Testado com TIM e OI e funcionou, porém é preciso configurar a APN, nada muito difícil como colocarei aqui.

Siga os passos como estou descrevendo que você vai atualizar seu aparelho.

Mas não se esqueça, é por sua conta e risco, não me responsabilizo por problemas. e sempre faça com a bateria 100% cheia.

Aqui está funcionando muito bem, então vamos ensinar:

está parte é a mesma que coloquei meses atrás e o procedimento ainda é o mesmo.

AVISO ESTE PROCEDIMENTO PODE ESTRAGAR SEU CELULAR, FAÇA POR SUA CONTA E RISCO!!!

BAIXE TODOS OS PROGRAMAS E A ROM ANTES DE QUALQUER COISA!

  • FAÇA ISSO SEMPRE COM SUA BATERIA 100% CARREGADA
  • Baixe e instale o Motorola Driver Installation – Windows aqui
  • Pegue a imagem do Android 2.2 aqui que instalaremos no celular e faça a descompactação;
  • Em seu Milestone, vá em Configurações -> Aplicativos -> Desenvolvimento -> Ative Depuração USB;
  • Conecte seu telefone ao computador pela porta USB utilizando o cabo de dados;
  • Espere até o Windows achar seu device, instalar os drivers e tal e coisa. Tudo isso feito, abra o RSD Lite e espere até que o device A853 apareça na tabela (Se por um acaso não aparecer na lista, desconecte o cabo USB e reconecte-o. Assim que conectar, selecione o modo usb “Phone Portal”. Algumas pessoas conseguiram resolver assim.);
  • Selecione o arquivo de imagem que você descompactou na caixa de texto e clique em Start.
  • Todo o processo vai demorar uns 10min e o telefone irá rebootar umas 3 vezes. O RSD Lite eventualmente pedirá pra ligar o celular manualmente. NÃO FAÇA ISSO. Seja paciente e espere até que esteja escrito “Finished e PASS” na tabela do RSD Lite.
  • ATENÇÃO SÓ DESCONECTE O CELULAR QUANDO VER AS PALAVRAS FINISHED E PASS. se desconectar, desligar ou mexer no seu aparelho antes disso o celular se transformará em um belo peso de papel!

Para configurar a APN só mexa no que estou colocando aqui, o resto deixe da forma que está.

CONFIGURAÇÕES –> SEM FIO E REDES –> REDES MÓVEIS –> NOME DOS PONTOS DE ACESSO –> CLIQUE EM OPÇÕES E NOVO APN

Salve e pronto já está configurado para usar para TIM. para outras operadoras consulte o google para encontrar facilmente.

Name = TIM
APN = tim.br
Username = tim
Password = tim

E agora a dica do leitor FULL CLICK que faz a mágica!!!!

Entre na Market e baixe o app MORE LOCALE 2

depois de instalado, clique em menu –> ADD LOCALE

de um nome para o LABEL ( eu coloquei Brasil) em Language fica PT ISO639

em COUTRY fica BR ISO 3166

Clique em ADD e pronto.

Seu Milestone 1 agora tem o FROYO e em Portugues do Brasil.”



Já uso o Froyo há uns 30 dias no meu Milestone. O Ed fez umas personalizações (O APN já é automático) e ficou muito bom e estável. Vale a pena conferir no site dele: http://shadowmodbr.wordpress.com



segunda-feira, dezembro 20, 2010

Howto: Asterisk PBX Holidays on your dial plan

Admin World | Howto: Asterisk PBX Greek National Holidays on your dial plan: "Howto: Asterisk PBX Greek National Holidays on your dial plan
Posted by admin on 09/04/2010 Leave a comment (2) Go to comments

Asterisk Logo

Well For some time now i work with asterisk servers and i try to learn as much as i can with a lot of reading and help from other IT friends.

This article is going to show how to tell asterisk which days of the year are holidays for Greece. It’s quite simple as principle but none of the greek IT community posted something similar to help the newbies, at least what i saw through Google. The most compicated part is where you must define the moving calendar holidays like easter and Clear Monday (??) :-) .

This scripting can also work with Other contries if you alter the dates on the astdb’s dates…

This example imports moving holidays to 2020 and standard calendar holidays for end of time….!

First of all create a file called what-ever-you-like.sh and imput the following lines:
#!/bin/sh
asterisk -rx 'database deltree holidays'
asterisk -rx 'database put holidays 20100215 1'
asterisk -rx 'database put holidays 20100402 1'
asterisk -rx 'database put holidays 20100405 1'
asterisk -rx 'database put holidays 20100524 1'
asterisk -rx 'database put holidays 20110307 1'
asterisk -rx 'database put holidays 20110422 1'
asterisk -rx 'database put holidays 20110425 1'
asterisk -rx 'database put holidays 20110613 1'
asterisk -rx 'database put holidays 20120227 1'
asterisk -rx 'database put holidays 20120413 1'
asterisk -rx 'database put holidays 20120416 1'
asterisk -rx 'database put holidays 20120604 1'
asterisk -rx 'database put holidays 20130318 1'
asterisk -rx 'database put holidays 20130503 1'
asterisk -rx 'database put holidays 20130506 1'
asterisk -rx 'database put holidays 20130624 1'
asterisk -rx 'database put holidays 20140303 1'
asterisk -rx 'database put holidays 20140418 1'
asterisk -rx 'database put holidays 20140421 1'
asterisk -rx 'database put holidays 20140609 1'
asterisk -rx 'database put holidays 20150223 1'
asterisk -rx 'database put holidays 20150410 1'
asterisk -rx 'database put holidays 20150413 1'
asterisk -rx 'database put holidays 20150601 1'
asterisk -rx 'database put holidays 20160314 1'
asterisk -rx 'database put holidays 20160429 1'
asterisk -rx 'database put holidays 20160502 1'
asterisk -rx 'database put holidays 20160620 1'
asterisk -rx 'database put holidays 20170227 1'
asterisk -rx 'database put holidays 20170414 1'
asterisk -rx 'database put holidays 20170417 1'
asterisk -rx 'database put holidays 20170605 1'
asterisk -rx 'database put holidays 20180219 1'
asterisk -rx 'database put holidays 20180406 1'
asterisk -rx 'database put holidays 20180409 1'
asterisk -rx 'database put holidays 20180528 1'
asterisk -rx 'database put holidays 20190311 1'
asterisk -rx 'database put holidays 20190426 1'
asterisk -rx 'database put holidays 20190429 1'
asterisk -rx 'database put holidays 20190617 1'
asterisk -rx 'database put holidays 20200302 1'
asterisk -rx 'database put holidays 20200417 1'
asterisk -rx 'database put holidays 20200420 1'
asterisk -rx 'database put holidays 20200608 1'

As you can see the first line removes all entries of the table holidays and then adds the holidays you want in the form %Y%m%d.

Now the line that calls astdb and checks if there is any time record matching the current time ( This is for 1.4) is:
exten => s,n,Set(HOLIDAYS=${DB_EXISTS(holidays/${STRFTIME(${EPOCH},GMT+2,%Y%m%d)})})
This line must be placed in a context that will run this command before starting doing the routing of the call. This command sets the ${HOLIDAYS} variable to 1 if the current date matches the records in the database, and to 0 if not.

Now there are several ways to route your call depending on the ${HOLIDAYS} variable value but i will show the most common and easy for me.

GotoIf Method:
exten => s,n,GotoIf($[${HOLIDAYS}>0]?,,)
This line says that if ${HOLIDAYS}>0 ie 1, then go to the context, context-name,priority and continiue from there. You could also to this:
exten => s,n,GotoIf($[${HOLIDAYS}>0]?,,: ,,)
which says that if it’s true to this else to that.

Now For a complete holidays definition i have set the following rules in the begining of the context that incoming calls are routed.
[context-for-incoming-calls]
exten => s,1,answer
exten => s,n,Set(HOLIDAYS=${DB_EXISTS(holidays/${STRFTIME(${EPOCH},GMT+2,%Y%m%d)})})
; Holidays
exten => s,n,GotoIfTime(*|*|1|jan? s,n,GotoIfTime(*|*|6|jan?context-ext-closed,closed,1)
exten => s,n,GotoIfTime(*|*|25|mar?context-ext-closed,closed,1)
exten => s,n,GotoIfTime(*|*|1|may?context-ext-closed,closed,1)
exten => s,n,GotoIfTime(*|*|15|aug?context-ext-closed,closed,1)
exten => s,n,GotoIfTime(*|*|28|oct?context-ext-closed,closed,1)
exten => s,n,GotoIf($[${HOLIDAYS}>0]?context-ext-closed,closed,1)
exten => s,n,GotoIfTime(*|*|25-26|dec?context-ext-closed,closed,1)
; Working Days
exten => s,n,GotoIfTime(09:00-17:00|mon-fri|*|*?context-ext-open,open,1)
exten => s,n,Goto(biznet-ext-closed,closed,1)
I think is quite straight forward if you look the dates on the definitions. These rules redirect the call to a context-ext-closed if the dates match, which handles the call from there.

I hope this article is usefull for somebody, and i am here to answer any question.

Enjoy!

- Sent using Google Toolbar"

sábado, dezembro 04, 2010

Routing for multiple uplinks/providers

what to do if you have more than one internet provider, two routers and one linux box?
4.2. Routing for multiple uplinks/providers

A common configuration is the following, in which there are two providers that connect a local network (or even a single machine) to the big Internet.

________
+------------+ /
| | |
+-------------+ Provider 1 +-------
__ | | | /
___/ \_ +------+-------+ +------------+ |
_/ \__ | if1 | /
/ \ | | |
| Local network -----+ Linux router | | Internet
\_ __/ | | |
\__ __/ | if2 | \
\___/ +------+-------+ +------------+ |
| | | \
+-------------+ Provider 2 +-------
| | |
+------------+ \________

There are usually two questions given this setup.
4.2.1. Split access

The first is how to route answers to packets coming in over a particular provider, say Provider 1, back out again over that same provider.

Let us first set some symbolical names. Let $IF1 be the name of the first interface (if1 in the picture above) and $IF2 the name of the second interface. Then let $IP1 be the IP address associated with $IF1 and $IP2 the IP address associated with $IF2. Next, let $P1 be the IP address of the gateway at Provider 1, and $P2 the IP address of the gateway at provider 2. Finally, let $P1_NET be the IP network $P1 is in, and $P2_NET the IP network $P2 is in.

One creates two additional routing tables, say T1 and T2. These are added in /etc/iproute2/rt_tables. Like this:

1 T1
2 T2



Then you set up routing in these tables as follows:

ip route add $P1_NET dev $IF1 src $IP1 table T1
ip route add default via $P1 table T1
ip route add $P2_NET dev $IF2 src $IP2 table T2
ip route add default via $P2 table T2


Nothing spectacular, just build a route to the gateway and build a default route via that gateway, as you would do in the case of a single upstream provider, but put the routes in a separate table per provider. Note that the network route suffices, as it tells you how to find any host in that network, which includes the gateway, as specified above.

Next you set up the main routing table. It is a good idea to route things to the direct neighbour through the interface connected to that neighbour. Note the `src' arguments, they make sure the right outgoing IP address is chosen.

ip route add $P1_NET dev $IF1 src $IP1
ip route add $P2_NET dev $IF2 src $IP2


Then, your preference for default route:

ip route add default via $P1


Next, you set up the routing rules. These actually choose what routing table to route with. You want to make sure that you route out a given interface if you already have the corresponding source address:

ip rule add from $IP1 table T1
ip rule add from $IP2 table T2


This set of commands makes sure all answers to traffic coming in on a particular interface get answered from that interface.

Now, this is just the very basic setup. It will work for all processes running on the router itself, and for the local network, if it is masqueraded. If it is not, then you either have IP space from both providers or you are going to want to masquerade to one of the two providers. In both cases you will want to add rules selecting which provider to route out from based on the IP address of the machine in the local network.
4.2.2. Load balancing

The second question is how to balance traffic going out over the two providers. This is actually not hard if you already have set up split access as above.

Instead of choosing one of the two providers as your default route, you now set up the default route to be a multipath route. In the default kernel this will balance routes over the two providers. It is done as follows (once more building on the example in the section on split-access):

ip route add default scope global nexthop via $P1 dev $IF1 weight 1 \
nexthop via $P2 dev $IF2 weight 1


This will balance the routes over both providers. The weight parameters can be tweaked to favor one provider over the other.

Note that balancing will not be perfect, as it is route based, and routes are cached. This means that routes to often-used sites will always be over the same provider.

Furthermore, if you really want to do this, you probably also want to look at Julian Anastasov's patches at http://www.linuxvirtualserver.org/~julian/#routes , Julian's route patch page. They will make things nicer to work with.


Script will look like this
vi route-add-eth0.sh
#START
#/bin/sh
IF1=eth0
IP1=192.168.10.2
P1=192.168.10.254
P1_NET=192.168.10.0


ip route add $P1_NET dev $IF1 src $IP1 table T1
ip route add default via $P1 table T1

ip route add $P1_NET dev $IF1 src $IP1

ip route add default via $P1

ip rule add from $IP1 table T1
#END